#pragma once
#include <iostream>
#include <opencv2/core/mat.hpp>
#include <opencv2/opencv.hpp>


using namespace cv;
using namespace std;

struct CameraParameters{
    int image_width = 640;
    int image_height = 480; 
    double frame_rate = 30.0;
    int auto_exposure = true;
    int exposure_time = 100;
    int gain = 16;

};

class UsbCamDriver {

public:
    UsbCamDriver();
    UsbCamDriver(string video_path);
    ~UsbCamDriver(); 
    
    void setCamera();
    void setCamera(const CameraParameters params);

    bool get_frame(cv::Mat& frame);

private:
    cv::VideoCapture cap;
    CameraParameters params;
    
};    